package com.hyw.cm.reg.service;

import java.util.List;

import org.springframework.lang.Nullable;

public interface ITemplateService<V, K> {

  /**
   * 大多数情况下，不允许返回全量数据
   * 
   * @throws UnsupportedOperationException
   */
  default List<V> list() {
    throw new UnsupportedOperationException();
  }

  @Nullable
  V findByKey(K key);

  void remove(K key);

  V create(V value);

}
